<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" >
<!--[if lt IE 9]>
　　　　<script src="http://css3-mediaqueries-js.googlecode.com/svn/trunk/css3-mediaqueries.js"></script>
　　<![endif]-->
<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/sytle.css?v=0.2&d=2016-11-08">
<script type="text/javascript" src="${pageContext.request.contextPath}/lib/jquery/1.9.1/jquery.min.js?v=0.1"></script> 
<script type="text/javascript">
$(document).ready(function(){
	var isShow = false;
	var is = true;
 	$("#btn_sub").click(function(){
 	   
 		var mobile = $("#mobile").val();
 	   	if(mobile == '' || mobile.length < 10 || isNaN(mobile)) {
 	   		$("#tip").show();
 	   		$("#tipMsg").text("请输入电话号码");
 		  	is = false; 
 		  	
 		  	close();
 		  	return;
 	   	}
 	    var password =  $("#password").val();
 	    if(password == '' || password.length < 6) {
 	    	$("#tip").show();
 	    	$("#tipMsg").text("请输入密码");
		  	is = false; 
		  	
		  	close();
		  	return;
	   	}
 	   	if(is) {
 	   		$("#loginForm").submit();
 	   	}
 	});
 	
 	function close() {
	 	setTimeout(function() {
	 		$("#tip").hide();
	 	}, 2000);
 	}
}); 
</script>
<title>登陆</title>
</head>
<body>
<div class="hgj">
  <div class="page-all"> 
    <!--头部开始-->
    <header>
      <div class="navbar">
        <ul>
          <li class="l-back"><a href="/"><img src="${pageContext.request.contextPath}/images/left.png" alt="返回"/></a></li>
          <li class="n-word">登陆</li>
          <li class="n-intro"></li>
        </ul>
      </div>
    </header>
    <!---内容开始--->
    <div class="container">
    <form id="loginForm" action="${pageContext.request.contextPath}/members/login.html" method="POST">
      <div class="former">
        <ul>
          <li>
            <input type="tel" pattern="[0-9]*" id="mobile" name="wMMobile" placeholder="请输入手机号码" maxlength="15" class="user-tel">
          </li>
          <li>
            <input type="password" pattern="*" id="password" name="wMPassword" placeholder="请输入密码" maxlength="20" class="user-tel">
          </li>
        </ul>      
        <div class="dn"><a id="go-register" href="${pageContext.request.contextPath}/members/register.html"> 立即注册</a><a href="${pageContext.request.contextPath}/members/restPwd.html">忘记密码？</a></div>
        <div class="login-btn"> <a href="javascript:void();" id="btn_sub">立即登陆</a> </div>
      </div>
     </form>
      <div align="center">${ERROR_INFO}</div>
      <!---提示弹窗(未输入手机号码的弹出框，注册点击后弹出，2秒后自动消失)--->
      <div class="login-layer" style=" display:none;" id="tip"> <span id="tipMsg"></span> </div>
    </div>
  </div>
</div>
</body>
</html>
